<template>
  <div class="question-main-container">
    <div class="all-answer">
      <div class="write" v-if="this.$store.state.writeAnswer">
        <write-answer :questionId="questionInfo.id"/>
      </div>
      <all-answer class="all-answer"/>
    </div>
    <div class="side-bar"><side-bar class="side-bar" /></div>
  </div>
</template>
<script>
import AllAnswer from "@/components/question/AllAnswer";
import SideBar from "@/components/question/sideBar/SideBar";
import WriteAnswer from "@/components/question/WriteAnswer";

export default {
  name: "QuestionMain",
  data() {
    return {
      
    }
  },
  props: {
    questionInfo: {
      type: Object,
      default() {
        return {};
      },
    },
  },
  components: {
    AllAnswer,
    SideBar,
    WriteAnswer,
  },
};
</script>

<style scoped lang="scss">
.question-main-container {
  display: flex;
  justify-content: space-between;
  width: 100rem;
  margin: 0 auto;
  min-width: 100rem;
  margin-top: 1rem;
  .all-answer {
    width: 71rem;
    box-shadow: 0 0.1rem 0.3rem rgba(18, 18, 18, 0.1);
  }
  .side-bar {
    width: 27rem;
    height: 20rem;
    background-color: red;
    box-shadow: 0 0.1rem 0.3rem rgba(18, 18, 18, 0.1);
  }
}
</style>